<template>
  <div>
    <p>{{ textVal }}</p>
    <p>
      <input type="color" :value="color"> {{color}}
    </p>
    <!--v-model与修饰符的用法，valModifiers-->
    <K v-model:textVal="textVal" v-model:colorVal.opacity="color" />
  </div>
</template>

<script setup lang='ts'>
import { ref, reactive } from 'vue'
import K from './25v-model/K.vue'

const textVal = ref('12')
const color = ref('#526499')

</script>

<style lang='scss' scoped>

</style>